package com.socialnetspace.service;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.socialnetspace.dao.IUserDAO;
import com.socialnetspace.domain.User;

@Service("UserService")
public class UserService {
	
	
	private Log logger = LogFactory.getLog(this.getClass().getName());
	
	@Autowired
	private IUserDAO userDAO;
	
	
	public boolean doUsernameExists(String username) {
		
		
		
		return false;
	}
	
	
	public void registerUser() {
		
		logger.info("Registering a new user ...");
		
		User user = new User();
		
		user.setUsername("test");
		user.setFirstName("Test");
		user.setLastName("Account");
		user.setEmailAddress("test@socialnetspace.com");
		
		userDAO.saveUser(user);
		
	}
	
}
